package com.example3.demo.rocketmq.message;

import com.example3.demo.utils.JsonUtil2;

/**
 * @author:
 * @Date: 19:25 2019/1/15
 */
public interface MessageProcessor<T> {
    boolean handleMessage(T message);

    Class<T> getClazz();

    default T transferMessage(String message) {
        return JsonUtil2.fromJson(message, getClazz());
    }
}
